#ifndef Path_h2__
#define Path_h2__

#include <string>
#include <vector>

namespace le
{
	class Path
	{
	public:
		Path();
		explicit Path(const std::string& path);
		explicit Path(const char* path);
		~Path();
		
		// Replaces all '\' or '\\' with '/'
		static le::Path NormalizePath(const le::Path& path);
		static le::Path NormalizePath(const char* path);

		static std::string GetExtension(const le::Path& path);
		static std::string GetFileName(const le::Path& path);
		static std::string GetFileNameNoExtension(const le::Path& path);

		// if the path would be a folder, it will just give the parent folder
		static std::string GetResidingFolder(const le::Path& path);

		static std::string GetFolderPath(const le::Path& path);

		/** Returns the current active working directory */
		static std::string GetWorkDirectory();

		/** Returns the absolute file path */
		static std::string GetAbsolutePath(const le::Path& relativePath);

		/** Returns all files located in the given path and filter*/
		static size_t GetFilesInPath(const le::Path& path, const char* filter, bool recursive, std::vector<le::Path>& out);

		const char* ToChar() const { return m_StoredPath.c_str(); }

	private:
		std::string m_StoredPath;
		static std::string m_RootPath;
	};
}

#endif // Path_h__